package com.hgyc.mom.tool.entity;

import java.time.LocalDateTime;
import java.io.Serializable;
import com.baomidou.mybatisplus.annotation.*;

import com.hgyc.mom.common.annotation.Excel;
import com.hgyc.mom.core.annotation.DictColumn;
import com.hgyc.mom.core.annotation.TableDict;
import com.hgyc.mom.core.mybatis.EQ;
import com.hgyc.mom.core.mybatis.Like;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
 * <p>
 * 产品标签记录
 * </p>
 *
 * @author fwj
 * @since 2025-07-24
 */
@Data
@TableName("tool_label_record")
@Schema(name="产品标签记录对象", description="产品标签记录对象")
public class ToolLabelRecord implements Serializable {
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @Schema(description = "")
    private Long id;

    @Schema(description = "工单ID")
    private Long workOrderId;

    @Excel(name = "产品ID")
    @EQ
    @Schema(description = "产品ID")
    @TableDict(table = "base_material", key = "id" , columns = {
            @DictColumn(name ="material_code", alias = "materialCode"),
            @DictColumn(name = "material_name", alias = "materialName")
    })
    private Long materialId;

    @Excel(name = "标签条码")
    @Like
    @Schema(description = "标签条码")
    private String labelCode;

    @Excel(name = "最小包装数量")
    @Schema(description = "最小包装数量")
    private Integer qty;

    @Excel(name = "标签状态")
    @Schema(description = "标签状态")
    private String status;

    @Excel(name = "打印时间")
    @EQ
    @Schema(description = "打印时间")
    private LocalDateTime printTime;

    @Excel(name = "打印人")
    @Schema(description = "打印人")
    @TableDict(table = "sys_user", key = "id", columns = {
            @DictColumn(name = "name", alias = "printUserName")
    })
    private Long printUser;

    @Excel(name = "补打时间")
    @Schema(description = "补打时间")
    private LocalDateTime reprintTime;

    @Excel(name = "补打人")
    @Schema(description = "补打人")
    @TableDict(table = "sys_user", key = "id", columns = {
            @DictColumn(name = "name", alias = "reprintUserName")
    })
    private Long reprintUser;

}
